﻿using System.Collections.Generic;
using System.Collections;
using System.IO;
using System.Xml;
using System.Xml.Serialization;
using System;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using System.Xml.Schema;

namespace ScormModel
{
    [Serializable()]
    public class Dependency
    {
        private String _identifierref;
         [NonSerialized]
        private XmlNode _dependencyContent;
        [XmlAttribute("identifierref")]
        public string Identifierref
        {
            get { return this._identifierref; }
            set { this._identifierref = value; }
        }
        
        [XmlIgnoreAttribute]
        public XmlNode DependencyContent
        {
            get { return this._dependencyContent; }
            set { this._dependencyContent = value; }
        }
        public void buildDependency()
        {
            XmlAttributeCollection attList = _dependencyContent.Attributes;
            for (int i = 0; i < attList.Count; i++)
            {
                if (attList[i].Name == "identifierref")
                {
                    _identifierref = attList[i].Value;
                }
            }
        }
    }
}
